package com.haochang.chunkvod.controller.adapter.hostess;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;
import android.view.View;

import java.util.ArrayList;

public class QuickFragmentPagerAdapter extends FragmentPagerAdapter {
	private ArrayList<Fragment> listFragments;

	public QuickFragmentPagerAdapter(FragmentManager fm,
									 ArrayList<Fragment> listFragments) {
		super(fm);
		this.listFragments = listFragments;
	}

	@Override
	public Fragment getItem(int position) {
		return null == listFragments ? null : listFragments.get(position);
	}

	@Override
	public int getCount() {
		return null == listFragments ? 0 : listFragments.size();
	}

	@Override
	public void setPrimaryItem(View container, int position, Object object) {
		super.setPrimaryItem(container, position, object);
	}
}
